package com.kawa.kemanage.service;

import com.kawa.kemanage.entity.AdCampaign;
import com.kawa.kemanage.exception.BadSqlException;
import com.kawa.kemanage.mapper.AdCampaignMapper;
import com.kawa.kemanage.mapper.AdvertiserMapper;
import com.kawa.kemanage.util.PageResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface AdCampaignService {
    List<AdCampaign> findAll() ;

    PageResult<AdCampaign> findByPage(Integer page, Integer size) ;

    AdCampaign findById(Integer id) ;

    PageResult<AdCampaign> findByAdvertiserIdAndPage(Integer advertiserId, Integer page, Integer size) ;

    AdCampaign create(AdCampaign campaign) ;

    AdCampaign update(Integer id, AdCampaign campaign) ;

    void delete(Integer id) ;

    // 分页查询已删除的广告计划
    PageResult<AdCampaign> findDeletedByPage(Integer page, Integer size);
}
